package com.edu.cdp.VO;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.Parameter;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

/**
 * 一张订单的数据
 */
@Data
public class OrderVO {
    @Parameter(description = "用户id")
    private Integer userId;

    @Parameter(description = "订单id")
    private Integer id;

    @Parameter(description = "订单支付时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime paymentTime;

    @Parameter(description = "订单编号")
    private String orderNo;

    @Parameter(description = "订单创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    @Parameter(description = "订单总价")
    private Double totalPrice;

    @Parameter(description = "订单支付状态")
    private Integer payStatus;

    @Parameter(description = "订单状态")
    private Integer status;

    @Parameter(name = "orderDetailsList", description = "订单详情列表")
    private List<OrderDetailsVO> orderDetailsList;
}
